package com.atcc.test.model;

import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;

public class ProxyHandler implements InvocationHandler{
	
	private Object object;
	
	public ProxyHandler(Object object) {
		this.object=object;
	}
	
	@Override
	public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
        System.out.println("before: " + method.getName());
        method.invoke(object, args);
        System.out.println("after: " + method.getModifiers());
		return null;
	}

}
